<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>dom树</title>
</head>
<body>
    <div>
        <div>
            <h2 id="title">关注我们</h2>
        </div>
        <div>
            <ul>
                <li>新浪微博</li>
                <li>官方微信</li>
                <li>联系我们</li>
                <li>公益基金会</li>
            </ul>
        </div>

    </div>
    <script>
        const title = document.getElementById("title")
        console.log(title.parentElement
                    .nextElementSibling
                    .firstElementChild
                    .firstElementChild
                    .nextElementSibling
                    .nextElementSibling
                    .innerHTML)
    </script>
</body>
</html>